package net.cyndeline.GameMap.dataStructure

import net.cyndeline.GameMap.LevelMap
import java.util.UUID
import net.cyndeline.entitySystem.EntityRef
import net.cyndeline.GameMap.Grid
import net.cyndeline.GameMap.Tile

/**
 * Default inject for maps. Should be replaced by
 * an actual implementation.
 */
class NullMap extends LevelMap {
  def build(id: UUID, grid: Grid, name: String) = { }
  def id: UUID = UUID.randomUUID()
  def objectsAt(x: Int, y: Int) = throw new Error("This a Null map, it should only be used as inject placeholder.")
  def width = 0
  def height = 0
  def addObject(entity: EntityRef) = false
  def removeObject(entity: EntityRef) = false
  def name = "I'm a Null map. I should've been replaced by a real map."
  def copy = new NullMap()
}